#ifndef EVENTPOLLER_H
#define EVENTPOLLER_H

#include "EventHandler.h"
#include "Singleton.h"

#include <set>
#include <D3DX11.h>

class EventPoller : public Uncopyable
{
private:
	EventPoller() {}
	friend class Singleton<EventPoller>;
public:
	void Update(const MSG& msg);
	void AddHandler(EventHandler*);
	void RemoveHandler(EventHandler*);

private:
	typedef std::set<EventHandler*> Handlers;
	Handlers m_handlers;
};

typedef Singleton<EventPoller> TheEventPoller;
#endif //EVENTPOLLER_H